<html>
	<head>
		<title>View MythTV Program</title>
		<script type="text/javascript" src="file:///android_asset/flowplayer-3.2.4.min.js"></script>
		
		<script type="text/javascript">
		
			function init( url, videoUrl, length ) {
			    window.android.info( "init : enter" );
				
				window.android.status( "videoUrl=" + videoUrl );
				window.android.status( "length=" + length );
				
				var config = {
						clip: {
							autoPlay: true,
							autoBuffer: true,
							accelerated: true
						},
						
						playlist: [										
        					{
        						url: videoUrl, 
        						duration: length
        					}				
    					]
					};
				
				
				$f(
					"player", 
					url + "/tv/flowplayer-3.1.1.swf",
					config
				);
				
			    window.android.info( "init : exit" );
			}

			function pause() {
			    window.android.info( "pause : enter" );
				
				$f( "player" ).pause();
				window.android.status( $f( "player" ).getStatus() );

			    window.android.info( "pause : exit" );
			}
			
			function resume() {
			    window.android.info( "resume : enter" );

				$f( "player" ).resume();
				window.android.status( $f( "player" ).getStatus() );
				
			    window.android.info( "resume : exit" );
			}
		</script>
	</head>

	<body>
		<div id="player"></div>
	</body>
</html>
